import com.fjnu.config.SpringConfig;
import com.fjnu.dao.UserDao;
import com.fjnu.model.User;
import org.testng.annotations.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(classes= SpringConfig.class)
public class AspectTest {

    @Autowired
    UserDao userDao ;
    @org.junit.Test
    @Test
    public void testUserDao() {
        userDao.insert(new User()) ;
        userDao.delete("001") ;
        userDao.update("001", new User());
        userDao.selectUserByNameAndPassword("001", "password");
    }


}
